<template>
  <div class="quick-nav-box">
    <nav class="quick-link-nav">
      <a href="#/" class="quick-link-item" v-for="item in data" :key="item.id">
        <span class="quick-box">
          <img :src="item.src" />
          <span class="quick-title">{{ item.title }}</span>
        </span>
      </a>
    </nav>
  </div>
</template>

<script>
export default {
  name: 'quickLinkNav',
  props: {
    data: Array
  }
}
</script>

<style lang="less" scoped>
.quick-nav-box {
  position: relative;
  overflow: hidden;
  z-index: 1000;
  width: 100%;
  height: 100%;
}

.quick-nav-box .quick-link-nav {
  display: flex;
  flex-wrap: wrap;
  overflow: hidden;
  padding: 10px 10px;
}

.quick-nav-box .quick-link-nav .quick-link-item {
  width: 88px;
  margin-top: 5px;
  text-align: center;
}

.quick-nav-box .quick-link-nav .quick-box {
  display: block;
  img {
    width: 40px;
    height: 40px;
  }
  span {
    display: block;
    line-height: 14px;
    font-size: 14px;
    color: rgb(102, 102, 102);
  }
}

.quick-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
</style>
